﻿using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Windows;
using wpffc.contracts.domaindata;
using wpffc.contracts.viewmodels.learning;

namespace wpffc.viewmodelmapping
{
    public class Map_card_to_learningVM
    {
        private LearningViewModel _vm;


        public void Inject(LearningViewModel dependency)
        {
            _vm = dependency;
        }


        public void Process(Card card)
        {
            Trace.TraceInformation("Map card to learningVM: {0}", card.Question);

            _vm.Question = card.Question;
            _vm.Answer = card.Answer;
            _vm.AnswerVisibility = Visibility.Hidden;

            _vm.ScoreKnowledgeCmd.In_IsEnabled(false);
        }
    }
}
